﻿using System;

namespace Core
{
    public class Plant: BaseObject
    {
        public string Name { get; private set; }
        public int Price { get; private set; }
        public PlantType Type
        {
            set
            {
                PlantingDate = DateTime.Now;
                switch (value)
                {
                    case PlantType.Potato:
                        Name = "Potato";
                        TimeToGrowup = 1F;
                        Price = 100;
                        break;
                    case PlantType.Flower:
                        Name = "Flower";
                        TimeToGrowup = 2F;
                        Price = 150;
                        break;
                }
            }
        }
        public DateTime PlantingDate { get; private set; }
        public double TimeToGrowup { get; private set; }
    }
}
